feat(frontend): batch approve/reject on global Tools page (MCP-2918)#723
Merged
Conversation
Add batch Approve and Reject (block) actions to the global Tools page, alongside the existing batch Enable/Disable. The page spans multiple servers, so the actions group the current multi-select by server_name and fan out one approveTools/blockTools call per server (Promise.all), aggregate counts, and show a single success/error toast. - Buttons (data-test batch-approve / batch-reject) enable only when the selection contains at least one pending/changed tool. - Already-approved tools in the selection are silently skipped. - Partial failures surface a per-server error toast. Related #MCP-2918
Deploying mcpproxy-docs with
|
| Latest commit: |
69f2fbf
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://aec266d7.mcpproxy-docs.pages.dev |
| Branch Preview URL: | https://feat-mcp-2918-batch-approve.mcpproxy-docs.pages.dev |
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
📦 Build ArtifactsWorkflow Run: View Run Available Artifacts
How to DownloadOption 1: GitHub Web UI (easiest)
Option 2: GitHub CLI gh run download 27811660317 --repo smart-mcp-proxy/mcpproxy-go
|
There was a problem hiding this comment.
Approved via independent reviewer verdict — KimiReviewer (MCP-2929): accept. QA PASS (MCP-2928, qa-gate green). CI fully green. Frontend-only batch approve/reject on the global Tools page; group-by-server fan-out, skip-approved, partial-failure toast. Merge gated by human confirmation (MCP-2918).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds batch Approve and batch Reject (block) actions to the global Tools page (
frontend/src/views/Tools.vue), alongside the existing batch Enable/Disable. The page spans multiple servers, so the actions group the current multi-select byserver_nameand fan out oneapproveTools/blockToolsAPI call per server.Parent: MCP-2916. Related MCP-2918.
Changes
data-test="batch-approve"/batch-reject, enabled only when the selection contains at least one tool whoseapproval_statusispendingorchanged.server_name, fan out oneapi.approveTools(server, names)/api.blockTools(server, names)per server viaPromise.all, aggregate counts, and show a single success/error toast (e.g. "Approved 7 tools across 3 servers").approvedtools in the selection are silently skipped (no error).Reuses the existing per-server
/api/v1/servers/{id}/tools/approve|blockendpoints (same client methods as MCP-2917). Frontend-only.Testing
frontend/tests/unit/tools-batch-approve.spec.ts(TDD, 6 cases): button-disabled guard, group-by-server fan-out with correct names, skip-approved, blockTools on reject, single success toast summarising tools/servers, partial-failure error toast.cd frontend && npx vitest run→ 209 passed (27 files).npx vue-tsc --noEmit→ clean.make build→ embedded bundle refreshed, Go binary builds.🤖 reviewers: please verify the group-by-server fan-out and the pending/changed guard.